package com.kgc.feign;
import com.kgc.bean.Jek;
import com.kgc.common.Dto;
import com.kgc.pojo.DmUser;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
@FeignClient(value = "dm-user-provide",fallback = FeignBack.class)
public interface FeignService {
    @RequestMapping(value = "/api/v/loadCurrentUserByToken", method = RequestMethod.POST)
    public Dto loadCurrentUserByToken(@RequestParam String key);
    @RequestMapping(value = "/api/p/login", method = RequestMethod.POST)
    public Dto login(@RequestBody DmUser dmUser) throws Exception;
    @RequestMapping(value = "/api/p/checkEmail", method = RequestMethod.POST)
    public Dto checkEmail(@RequestParam String phone);
    @RequestMapping(value = "/api/p/code", method = RequestMethod.POST)
    public Dto code(@RequestParam String phone);
    @RequestMapping(value = "/api/p/register", method = RequestMethod.POST)
    public Dto register(@RequestBody Jek jek) throws Exception;
    @RequestMapping(value = "/api/user/msg", method = RequestMethod.POST)
    public Dto msg(@RequestParam String phone);
    @RequestMapping(value = "/api/user/login", method = RequestMethod.POST)
    public Dto login_user(@RequestBody Jek jek) throws Exception;
}
